#类的继承

class Yueqi :
    def sound(self):
        pass

class Erhu(Yueqi):
    def sound(self):
        print('二胡在演奏')

class Piano(Yueqi):
    def sound(self):
        print('钢琴在演奏')
class  Violin(Yueqi):
    def sound(self):
        print('小提琴在演奏')


def play(Yueqi) :
    Yueqi.sound()

class Bird :
    def sound(self):
        print('小鸟在唱歌')

if __name__ == '__main__' :
    play(Erhu())
    play(Piano())
    play(Violin())
    play(Bird())



